<%@ page import="lsy.tools.SessionCounter" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>

<html>
<head>
    <meta charset="UTF-8">
    <title>首页</title>
    <link rel="stylesheet" href="${basePath}style.css">
    <link rel="stylesheet" href="${basePath}font-awesome-4.7.0/css/font-awesome.min.css">
    <script src="https://code.jquery.com/jquery-3.6.0.min.js" type="text/javascript"></script>
    <script>
        $(function (){
            $('.menux p').click(function (){
                $(this).siblings('ul').slideUp(200);
                $(this).next('ul').slideToggle(200);
            });
            $('.menux ul a').click(function (){
                $('iframe').attr("src",$(this).attr("url"));
                $('.menu_title').html($(this).attr("title"));
            });

            $('.logout').click(function (){
                if (confirm("确定要退出吗？")){
                    window.location.href="logout";
                }
            });
        })
    </script>
</head>
<body>
<div class="header">
    <div class="logo">学生选课系统</div>
    <div class="user">
        <i class="fa fa-caret-down point"></i>
        <i class="fa fa-user"></i>
        帮助
        <ul>
            <li><a href="javascript:void (0)">修改密码</a> </li>
            <li><a href="javascript:void (0)">个人信息</a></li>
            <li><a href="javascript:void (0)" class="logout">退出登录</a></li>
        </ul>
    </div>

</div>
<div class="left">
    <div class="title">
        <i class="fa fa-home">  </i>
        系统功能
    </div>
    <div class="menux">
        <c:if test="${type==2}">
        <p>
            <i class="fa fa-info-circle"></i>
            管理员操作
            <i class="fa fa-angle-right point"></i>
        </p>
        <ul>
            <li>
                <a href="javascript:void (0);" url="${basePath}student?method=list" title="学生管理">
                    <i class="fa fa-caret-right"></i>
                    学生管理
                </a>
            </li>
            <li>
                <a href="javascript:void (0);" url="${basePath}teacher?method=list" title="老师管理">
                    <i class="fa fa-caret-right"></i>
                    老师管理
                </a>
            </li>
            <li>
                <a href="javascript:void (0);" url="${basePath}course?method=list" title="课程管理">
                    <i class="fa fa-caret-right"></i>
                    课程管理
                </a>
            </li>
        </ul>
        </c:if>
        <c:if test="${type==1}">
        <p>
            <i class="fa fa-info-circle"></i>
            老师权限
            <i class="fa fa-angle-right point"></i>
        </p>
        <ul>
            <li>
                <a href="javascript:void (0);" url="list.jsp" title="子功能1">
                    <i class="fa fa-caret-right"></i>
                    评分
                </a>
            </li>
        </ul>
        </c:if>
        <c:if test="${type==0}">
        <p>
            <i class="fa fa-info-circle"></i>
            学生权限
            <i class="fa fa-angle-right point"></i>
        </p>
        <ul>
            <li>
                <a href="javascript:void (0);" url="${basePath}sc?method=select" title="子功能1">
                    <i class="fa fa-caret-right"></i>
                    选课
                </a>
            </li>
        </ul>
        </c:if>
    </div>


</div>
<div class="main">
    <div class="location">
        <i class="fa fa-home"></i>
        <span class="menu_title">用户管理</span>

    </div>
    <iframe src="home.jsp" width="100%" height="100%" frameborder="0"></iframe>

</div>
</body>


</html>